﻿<div class="form-group " data-bind="css: { 'has-error': code.hasError }">
    <label> Code </label> 
    <input type="text" class="form-control" data-bind="value: code, hasFocus: true"/>
    <span class="help-block" data-bind="visible: code.hasError, text: code.validationMessage "></span>
</div>
<div class="form-group" data-bind="css: { 'has-error': title.hasError }">
    <label> Title </label> 
    <input type="text" class="form-control" data-bind="value: title"/>
    <span class="help-block" data-bind="visible: title.hasError, text: title.validationMessage "></span>
</div>